home *** CD-ROM | disk | FTP | other *** search
/ Belgian Amiga Club - ADF Collection / BS1 part 05.zip / BS1 part 5 / LSD.adf / docs / ToolsDaemon.doc.pp / ToolsDaemon.doc
Text File  |  1990-09-13  |  14KB  |  422 lines

  1.  
  2.  
  3.      
  4.  
  5.  
  6.                                 ToolsDaemon 2.0
  7.  
  8.                                   User Manual
  9.  
  10.                                   Jul 31, 1992
  11.  
  12.  
  13.  
  14.      PREFACE 
  15.  
  16.         The programs   and   files   in   this   distribution   are  freely
  17.      distributable,  but  are also Copyright (c) Nico Francois. They may be
  18.      freely  distributed  as  long as no more than a nominal fee is charged
  19.      to cover time and copying costs.  
  20.         No commercial  usage  is  permitted without written permission from
  21.      the  author. Everything in this distribution must be kept together, in
  22.      original unmodified form.  
  23.         The above is generally known as freeware.  
  24.  
  25.         If you  have  suggestions  or remarks about this program, or if you
  26.      find any bugs, please let me know.  
  27.  
  28.         Contacting the author: 
  29.  
  30.           Fido:  2:292/603.10 (Nico Francois)
  31.  
  32.           UUCP:  Nico.Francois@p10.f603.n292.z2.FidoNet.Org
  33.  
  34.           Mail:  Nico François
  35.                  Corbielaan 13
  36.                  B-3060 Bertem
  37.                  BELGIUM
  38.  
  39.         If you  can  please use e-mail. That way you'll stand a much better
  40.      chance of getting a reply quickly.  
  41.  
  42.         ToolsDaemon uses  and  requires  reqtools.library  V37 (or higher).
  43.      ReqTools is also Copyright © 1991/1992 Nico François.  
  44.  
  45.         NOTE: ToolsDaemon  2.0  requires Kickstart 2.0 and Workbench 2.0 or
  46.      higher to run! 
  47.  
  48.  
  49.      1. Introduction 
  50.      --------------- 
  51.  
  52.         Your Workbench  2.0  manual will tell you:  It is possible to run a
  53.      program  by  choosing  a  menu  item  from the Tools menu of Workbench
  54.      2.0.   But  only  if  your application software supports this feature.
  55.      Your  application software will have instructions on how to create the
  56.      new menu item.  
  57.  
  58.  
  59.  
  60.                                      Page 1
  61.  
  62.  
  63.      
  64.  
  65.  
  66.         But what  if  you  want  to  add programs to Workbench's menu strip
  67.      which do not have this feature?  Then there is ToolsDaemon 2.0.  
  68.  
  69.         ToolsDaemon allows  you  to run programs simply by selecting a menu
  70.      item  from  the  menu  strip  of  Workbench  2.0.  Shell and Workbench
  71.      programs  are  supported,  including arguments and tool types for both
  72.      of  these.   The  menu  items  can  be arranged in several menus, with
  73.      sub-items and keyboard shortcuts.  
  74.  
  75.         ToolsPrefs is  designed as a preferences editor for the ToolsDaemon
  76.      menus.   It  features  a full intuition front-end and supports the 2.0
  77.      AppWindow  feature.   This  means  it allows you to drag programs into
  78.      its  window  and  they  will  be automatically added to the menu items
  79.      list.  
  80.  
  81.         ToolsDaemon is  the  background  program that will launch the tools
  82.      you  select  from  the menu strip.  It is meant to be dragged into the
  83.      WbStartup drawer so it will automatically be launched on startup.  
  84.  
  85.  
  86.      2. Installation 
  87.      --------------- 
  88.  
  89.         Installation is  very  easy.   Double-click  the  'Install_Handler'
  90.      icon  to  install  'ToolsDaemon-handler'.   Then drag 'ToolsDaemon' to
  91.      your  WbStartup  drawer  so it will be launched by Workbench each time
  92.      you boot.  
  93.  
  94.         ToolsPrefs requires  'reqtools.library'  to  run, so make sure this
  95.      is    present    in    your   Libs:   directory.    Double-click   the
  96.      'Install_ReqTools'     icon    for    an    automatic    installation.
  97.      reqtools.library  exists  in  two  versions, one for Kickstart 1.2/1.3
  98.      and  one  for  2.0.   Note  that  only the version for 2.0 is included
  99.      since ToolsDaemon 2.0 only runs on Kickstart 2.0 or higher.  
  100.  
  101.         ToolsPrefs can  be  dragged  to  the Prefs drawer of your Workbench
  102.      2.0  partition,  but  you  can  install  it  anywhere you want.  It is
  103.      however  a  good  idea  to  install  it  somewhere in your CLI command
  104.      path.  
  105.  
  106.  
  107.      3. Usage 
  108.      -------- 
  109.  
  110.         Once everything   is   installed   run  ToolsDaemon  and  then  the
  111.      ToolsPrefs  program.  This will allow you to define the menus and menu
  112.      items  you  would  like  to  add  to  the menu strip of the Workbench.
  113.      ToolsPrefs  has  two  lists:   'Menu  Items' and 'Commands'.  The menu
  114.      items  list  corresponds  to  the  text  that  will appear in the menu
  115.      items.   Each  menu item has its own command list.  So by choosing one
  116.      menu item you can invoke several commands (asynchronously).  
  117.  
  118.  
  119.  
  120.                                      Page 2
  121.  
  122.  
  123.      
  124.  
  125.  
  126.         ToolsPrefs features  a  full  intuition front-end to edit the items
  127.      and  commands  lists.   Everything  is fairly self-explanatory, except
  128.      maybe  the  'Bubble  Up'  and  'Bubble  Down' menu items in the 'Edit'
  129.      menu.   These  allow  you  to  change  the order of the menu items, by
  130.      allowing  you to move the current item closer to the top ("bubble up")
  131.      or to the bottom of the list ("bubble down").  
  132.  
  133.         Items can  be  set  to  be  a menu title, a sub-item or a seperator
  134.      bar.   Use  the  'Menu' and 'Sub' checkboxes to set an item's type (if
  135.      none  of  these is checked the item is a normal menu item).  The 'Bar'
  136.      button will set the current menu item to be a seperator bar.  
  137.  
  138.         The 'Key'  string  gadget can be used to assign a keyboard shortcut
  139.      to  an  item.  Note that you can only use keys that aren't used by the
  140.      Workbench.   You  are  not  limited to using letters, but you can also
  141.      use numbers or other symbols (e.g. '1', '-', '/').  
  142.  
  143.         Commands can  be  run  as  Workbench  or  Shell commands.  Commands
  144.      indicated  as Workbench commands will be loaded and run by ToolsDaemon
  145.      just  as  if  you  had  double-clicked  them  in the Workbench.  Shell
  146.      commands  will  be  executed with a command line as if they were typed
  147.      in in a Shell window.  
  148.  
  149.         ToolsPrefs supports  the  use  of  arguments.  If you select one or
  150.      more  icons before selecting an item from the 'Tools' menu these files
  151.      will be passed as arguments.  
  152.  
  153.         If the  command is a Workbench command the arguments will be passed
  154.      as  if  you  selected  the program's icon and Shift-clicked some other
  155.      icons.   For  this  to  work  the  command  has to be followed by '[]'
  156.      indicating  it  expects  to  get  arguments.   For  example:   '(WB  )
  157.      C:PPMore []'.  
  158.  
  159.         If the  command  is  a Shell command the arguments will be expanded
  160.      onto  its  command line.  You should indicate with '[]' where you want
  161.      the arguments to appear.  For example:  '(CLI) Type [] HEX'.  
  162.  
  163.         The number  gadget next to the command string gadget determines the
  164.      stack  size  for  the  command  (in  case of a Shell command).  If the
  165.      command  is  launched  as a Workbench tool the stack size will be read
  166.      from the tool's icon.  
  167.  
  168.         The easiest  way  to  add an item is to pick up an icon and drop it
  169.      in  the  ToolsPrefs  window.   This will create a new item named after
  170.      the  program with a command list to run the program.  Dropping an icon
  171.      in  the  'Commands'  listview will not result in the creation of a new
  172.      item, but in adding a new command to the current command list.  
  173.  
  174.         When you  select  'Save'  ToolsPrefs  will  check if ToolsDaemon is
  175.      running  and  will  tell  it  to  update  the  menus  if it is.  It is
  176.      therefore  advisable  to  call ToolsPrefs if ToolsDaemon is already up
  177.      and  running.   If  you  have  dragged  ToolsDaemon  to your WbStartup
  178.  
  179.  
  180.                                      Page 3
  181.  
  182.  
  183.      
  184.  
  185.  
  186.      drawer  as  suggested  above it will always be running and you'll have
  187.      nothing to worry about.  
  188.  
  189.         Double-clicking the  icon  of  a  menu file saved with 'Save As...'
  190.      will  result  in  adding  the  menus to the Workbench's menu strip (if
  191.      ToolsDaemon  is  already  running the previously added menu items will
  192.      be removed first).  
  193.  
  194.      NOTE: - ToolsDaemon will search the path for Shell commands and
  195.              Workbench tools, but not for the icons of Workbench tools!
  196.              This exactly emulates the behaviour of Workbench 2.0.  
  197.            - Start ToolsDaemon again to quit it.  
  198.            - ToolsDaemon always adds an item to the 'Tools' menu of the
  199.              Workbench.  The item is called 'ToolsPrefs...' and when
  200.              picked will run the ToolsPrefs program.  The program will be
  201.              looked for in your command path and will be run as a Shell
  202.              command.  
  203.  
  204.  
  205.      4. Arguments and tooltypes 
  206.      -------------------------- 
  207.  
  208.      4.1 CLI or Shell 
  209.  
  210.         ToolsPrefs offers following command line arguments: 
  211.  
  212.           ToolsPrefs [FROM] [<menufile>] [PUBSCREEN <pubscreenname>] 
  213.  
  214.      [FROM] [<menufile>]         : Menu file to load instead of the
  215.                                    default 's:ToolsDaemon.menu' 
  216.      [PUBSCREEN <pubscreen name>]: Open editor on this public screen.  
  217.  
  218.  
  219.      4.2 Workbench 
  220.  
  221.         Following tooltypes are recognized: 
  222.  
  223.      CREATEICONS=<YES or NO>     : State of 'Create Icons?' menu item.
  224.                                    Default is YES.  Note that if
  225.                                    ToolsPrefs is started from the Shell
  226.                                    the menu item will not be checked so no
  227.                                    icons will be created.  
  228.      PUBSCREEN=<pubscreen name>  : Open editor on this public screen.  
  229.  
  230.  
  231.                          As always, I hope you find these programs useful! 
  232.  
  233.  
  234.  
  235.  
  236.  
  237.  
  238.  
  239.  
  240.                                      Page 4
  241.  
  242.  
  243.      
  244.  
  245.  
  246.                                 PROGRAM HISTORY
  247.  
  248.      ********************************************************************** 
  249.      VERSION 1.0 
  250.  
  251.      o First release.  
  252.  
  253.      ********************************************************************** 
  254.      VERSION 2.0 
  255.  
  256.      SEVERAL MAJOR ENHANCEMENTS! 
  257.      ~~~~~~~~~~~~~~~~~~~~~~~~~~~ 
  258.      o Features  multiple  menus,  submenus  and  keyboard shortcuts.  Much
  259.        more useful now! 
  260.      o Internal  function of preferences editor rewritten (now uses a state
  261.        machine), thanks to Marc Duponcheel for suggesting this.  
  262.      o More compatible Workbench startup: 
  263.        - All  tools  will  be  looked  for in Workbench's path.  The icon's
  264.          path must however be complete.  
  265.        - PROGDIR: is now supported (also for default tools, see below).  
  266.        - Workbench  tooltype  'TOOLPRI' supported (to set the task priority
  267.          of the tool).  
  268.        - Project   icons  supported.   ToolsDaemon  will  now  run  project
  269.          icons.   It  will  look  for  the  default tool of the icon in the
  270.          Workbench's  path  and  will  start  it  (even if it hasn't got an
  271.          icon) passing the project icon as the first argument.  
  272.      o More compatible Shell command execution: 
  273.        - Commands  are  now  sent  to  the  user shell, instead of the boot
  274.          shell.  
  275.        - Commands  now  receive  input  from  as well as send output to the
  276.          default console window.  
  277.  
  278.      RED ALERT -- RED ALERT -- RED ALERT...  
  279.      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 
  280.      ToolsDaemon  is  no  longer  a 100% legal program!  It patches certain
  281.      Intuition  functions  to  attach  menu items to Workbench's menu strip
  282.      (which  it  shouldn't touch) and redirects Workbench's message port in
  283.      order  to  trap  IDCMP_MENUPICK  messages  before Workbench sees them.
  284.      Everything  has  been  done  as  cleanly  as possible and should be as
  285.      future  compatible  as  it  can  be, but there is no real guarantee it
  286.      will  still work on future versions of the Amiga operating system.  If
  287.      you  can't  live  with  this continue to use ToolsDaemon 1.0, but know
  288.      that  the  features  ToolsDaemon  offers (multiple menus, submenus and
  289.      keyboard  shortcuts)  CANNOT be offered in a legal way, simply because
  290.      workbench.library  V37  doesn't support them.  If a new version of the
  291.      Amiga  operating  system is released and ToolsDaemon is not compatible
  292.      I will rectify this as soon as possible.  
  293.  
  294.      ********************************************************************** 
  295.  
  296.  
  297.  
  298.  
  299.  
  300.                                      Page 5
  301.  
  302.  
  303.      
  304.  
  305.  
  306.      ToolsDaemon 2.0 by Nico François (Yes, Nico is my first name :-) 
  307.                      thanks to Marc Duponcheel, Jorrit Tyberghein, Peter
  308.                                Stuer, Ives Aerts, Gunter Indenhoek and
  309.                                Alain Penders for beta-testing and all the
  310.                                useful suggestions, Johan Van Houtven for
  311.                                the editing of this manual.  
  312.  
  313.  
  314.      "He was struck by a bullet
  315.       and he melted into fluid named extinction" - Pixies
  316.  
  317.  
  318.      Copyright (c) 1991/1992 Nico François 
  319.  
  320.                  //
  321.      Thanks to \X/ Amiga for being the best computer ever!
  322.  
  323.  
  324.  
  325.  
  326.  
  327.  
  328.  
  329.  
  330.  
  331.  
  332.  
  333.  
  334.  
  335.  
  336.  
  337.  
  338.  
  339.  
  340.  
  341.  
  342.  
  343.  
  344.  
  345.  
  346.  
  347.  
  348.  
  349.  
  350.  
  351.  
  352.  
  353.  
  354.  
  355.  
  356.  
  357.  
  358.  
  359.  
  360.                                      Page 6
  361.  
  362.  
  363.      
  364.  
  365.  
  366.                                Table Of Contents
  367.  
  368.                                 ToolsDaemon 2.0
  369.  
  370.      PREFACE.........................................................    1
  371.  
  372.      1. Introduction.................................................    1
  373.  
  374.      2. Installation.................................................    2
  375.  
  376.      3. Usage........................................................    2
  377.  
  378.      4. Arguments and tooltypes......................................    4
  379.         4.1 CLI or Shell.............................................    4
  380.         4.2 Workbench................................................    4
  381.  
  382.      PROGRAM HISTORY.................................................    5
  383.  
  384.  
  385.  
  386.  
  387.  
  388.  
  389.  
  390.  
  391.  
  392.  
  393.  
  394.  
  395.  
  396.  
  397.  
  398.  
  399.  
  400.  
  401.  
  402.  
  403.  
  404.  
  405.  
  406.  
  407.  
  408.  
  409.  
  410.  
  411.  
  412.  
  413.  
  414.  
  415.  
  416.  
  417.  
  418.  
  419.  
  420.      
  421.  
  422.